const getters = {

    getCartData(state){
        if(state.oldList.length == 0 || state.oldList == null){
            
            state.oldList = JSON.parse(localStorage.getItem('cartList'))
            // if(state.oldList == null){
                // console.log("vuex getters=====>",state.oldList)
            //     state.oldList = []
            // }
        }

       return state.cartList
    }

}

export default getters